package com.bjsxt.buyaction.redisDao.impl;

import com.bjsxt.buyaction.redisDao.RedisItemDao;
import com.bjsxt.livegoods.pojo.Item;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.stereotype.Repository;

/**
 * @ClassName : RedisItemDao
 * @Description :
 * @Author : ZWZ
 * @Date: 2021/8/27 14:33
 */
@Repository
public class RedisItemDaoImpl implements RedisItemDao {

    @Autowired
    private RedisTemplate redisTemplate;

    @Override
    public Item get(String key) {
        return (Item) redisTemplate.opsForValue().get(key);
    }

}
